fix(docker): pin Poetry to 2.2.1 for Python 3.9 compatibility#8735
Open
rodrigoluizs wants to merge 1 commit intoapache:mainfrom
Open
fix(docker): pin Poetry to 2.2.1 for Python 3.9 compatibility#8735rodrigoluizs wants to merge 1 commit intoapache:mainfrom
rodrigoluizs wants to merge 1 commit intoapache:mainfrom
Conversation
Poetry 2.3.0 dropped Python 3.9 support. Without cache the installer fetches the latest version (currently 2.3.2), which fails on the python:3.9-slim-bookworm base image. Pin to 2.2.1, the last release compatible with Python 3.9.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Title: fix(docker): pin Poetry to 2.2.1 for Python 3.9 compatibility
Base:
main(apache/incubator-devlake)Summary
The
backend/Dockerfileinstalls Poetry without pinning a version:RUN curl -sSL https://install.python-poetry.org | python3 -Poetry 2.3.0 dropped support for Python 3.9. Since the base image uses
python:3.9-slim-bookworm, the unpinned installer now fetches an incompatible version (currently 2.3.2), causing the build to fail when there is no Docker layer cache available.Reference: https://python-poetry.org/blog/announcing-poetry-2.3.0/
Current CI builds succeed only because the cached
devlake:baseimage still contains a Poetry layer from a previous compatible version. Any cache invalidation (base image security update, forced rebuild, new registry) will break the build with:This PR pins Poetry to 2.2.1, the last release compatible with Python 3.9.
Does this close any open issues?
Closes #8734
Screenshots
N/A
Other Information
An alternative approach would be to upgrade the base image to Python 3.10+ to support Poetry 2.3+, but that has a larger blast radius.